﻿using System.Collections.Generic;
using System.ServiceModel;
using System.ServiceModel.Web;
using Acaweb.Model.Entities;

namespace Acaweb.Servicios.Contracts
{
    // NOTE: You can use the "Rename" command on the "Refactor" menu to change the interface name "IPensumService" in both code and config file together.
    [ServiceContract]
    public interface IPensumService
    {
        /// <summary>
        /// Retorna un único Pensum
        /// </summary>
        /// <param name="Id"></param>
        /// <returns></returns>
        [WebInvoke(Method = "POST", UriTemplate = "GetById", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        [OperationContract]
        Pensum GetById(Acaweb.Model.Entities.DatosCompuestos.PensumPk Id);

        /// <summary>
        /// Retorna todos los pensum asociados a un Plan de Estudios
        /// </summary>
        /// <param name="CodigoPlan"></param>
        /// <returns></returns>
        [WebInvoke(Method = "POST", UriTemplate = "GetByPlanEstudio", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        [OperationContract]
        List<Pensum> GetByPlanEstudio(int CodigoPlan);

        [WebInvoke(Method = "POST", UriTemplate = "GetCurrentPensum", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json)]
        [OperationContract]
        List<Pensum> GetCurrentPensum(int Estudiante);
    }
}
